T-SQL To Generate Select and Insert into scripts only for columns that have values
$10-30 USD
Chiuso
Pubblicato più di un anno fa
$10-30 USD
Pagato al completamento
I have a script that will generate the Select statement for only columns that are not nullable. But, what I need is a script that will generate the Select and Insert into statements for only columns that have values in the table. That is because we always have dozens of columns that are not used. Database create script attached. Sql Server 2016
DECLARE @table nvarchar(261) = N'[dbo].[table1]';
;WITH x AS
(
SELECT name, system_type_name,
column_ordinal = ROW_NUMBER() OVER (ORDER BY column_ordinal)
FROM sys.dm_exec_describe_first_result_set(N'SELECT * FROM ' + @table, N'', 0)
WHERE is_nullable = 0
AND is_identity_column = 0
AND is_computed_column = 0
)
SELECT N'INSERT ' + @table + N'(', N'--', column_ordinal = 0
UNION ALL
SELECT CHAR(13) + CHAR(10) + CASE column_ordinal
WHEN 1 THEN N'' ELSE N',' END + QUOTENAME(name),
N'--', column_ordinal
FROM x
UNION ALL
SELECT N'
) VALUES (', N'--', 1000
UNION ALL
SELECT CHAR(13) + CHAR(10) + CASE column_ordinal
WHEN 1 THEN N'' ELSE N',' END
+ N'<' + name + N', ' +system_type_name + N',>',
N'--', 1000 + column_ordinal
FROM x
UNION ALL
SELECT N'
);', N'--', 10000
ORDER BY column_ordinal;
*/
/*
INSERT [dbo].[table1](
[IDNUM]
,[c1]
,[c2]
,[c3]
,[c7]
) VALUES (
<IDNUM, int,>
,<c1, varchar(9),>
,<c2, int,>
,<c3, int,>
,<c7, numeric(8,2),>
);
*/
Please reply with:
The time of day that you are available. I am available 7am to 10pm UTC-06:00 Central Time US & Canada. Will you require contact by voice and do you speak English? When you can complete the project.
Confidentiality.
a) No Use. Recipient agrees not to use the Confidential Information in any way, or to manufacture or test any product embodying Confidential Information, except for the purpose set forth above.
b) No Disclosure. Recipient agrees to use its best efforts to prevent and protect the Confidential Information, or any part thereof, from disclosure to any person other than Recipient's employees having a need for disclosure in connection with Recipient's authorized use of the Confidential Information.
c) Protection of Secrecy. Recipient agrees to take all steps reasonably necessary to protect the secrecy of the Confidential Information, and to prevent the Confidential Information from falling into the public domain or into the possession of unauthorized persons.
d) Scope. The scope of Confidentiality is deemed to be in all contracts present past and future with the Parties to this request
I can help you with sql server queries, please ping/connect me now I am available.
Please check my reviews and project which I have completed.
I can create sql queries for sql server database as per design, let me know when to proceed. I can work on future works for databases also if needed.
I will work for cheapest budget within time, budget can be re negotiated again, send the details for the project. Please contact me asap.
I have 12+ years of experience in database programming, website designing, powershell scripting and android development.
Feel free to message me anytime if you need to discuss this further.
Hi I have 15 years experience with sql server database development, mysql database development, performance tuning. I will be able to help you with the project. Please ping me offline to discuss further.
Greetings!
I can help you with your project at a high level!
I have lots of experience in SQL Server, T-SQL, SSMS.
My skills and experience is a great match for your needs.
Looking forward to hearing from you.
Best regards.
Hi there, Good day,I have 6 years of experience in freelancer industry. I read your job description carefully I can provide you solid work in good time. Discuss on chat where I can easily share my explanation about your project if you think we are on the right track then hire me. I totally understand what you are looking for. check my profile. Thanks.
^⭐Hi there⭐^., I am an experienced web developer.
I have 7 years of experience and have strong knowledge inT-SQL.
I have read the details of your project,
I can definitely work for you as per your requirements.
I am available to work right now.
Please message me to discuss
Hi, I can help you with T-SQL scripts. I am available matching your time zone, 7am to 10pm. I can finish the task in a day.
Also I dont think I require contact by voice, but if needed I do speak English.
I have more than 15 years of IT experience with various database technologies. Working Knowledge of Postgres,Oracle Databases.
I have working experience in postgres database development as well as DBA.
Expertise in developing skill , proficient in PL/PG-SQL,PL-SQL writing stored procedures, triggers and functions.
Worked in build complex query.
Database tuning experience.
Good written and client interaction skills at all management level. Energetic self-starter and can learn new technology in short time.
Tuning query performance and recommending better way to optimize SQL queries and pl-pgsql/T SQL programs
Migration experience from Oracle to Postgres, Postgres to MS-SQL. Performed migration till 5 TB of Databases.
Having Developing/DBA experience of postgres database size more than 10 TB
Hello,
Hope you are good. So let's talk about the job. I gone through the job description and found you are going to modify the existing Scripts. My question is how many Scripts you want to modify? I am expert in writing Scripts specially to update the tables. We will discuss and start working.
Apart from the job description you provided if you want to modify SSIS Packages related to this SP then I can do this as well.
Ok. Waiting for your positive response.
Thank you! Have a great day.
Hello there,
I have read your requirements and am confident I am the right candidate for the job. Among other things, I have over ten years of experience in Oracle PLSQL, PostgreSQL, MySQL, MS SQL, and others. Furthermore, I am available 24x7 to answer any questions you may have about the requirements. I look forward to hearing from you as soon as possible
I would appreciate it if you would click the chat button for me if you are interested. Thanks a lot.
Best regards.
I can make changes to the script as required and available at the given time and I speak English. We can even do it faster if requirement is discussed further on call or msg.