Find Jobs
Hire Freelancers

Improve a MS-SQL Query with a Loop

€8-30 EUR

Fullført
Lagt ut omtrent 6 år siden

€8-30 EUR

Betalt ved levering
We need a improvement of a MS-SQL Query - At the moment the query looks like this: declare @InventurDatum AS DATETIME; declare @InventurDatum2 AS DATETIME; SET @InventurDatum = CONVERT(datetime, '01/03/2018 00:00:00', 103); SET @InventurDatum2 = CONVERT(datetime, '28/03/2018 23:59:59', 103); SELECT [login to view URL], [login to view URL], [login to view URL], ( select sum([login to view URL]) from tbestellpos asdf LEFT JOIN tBestellung bes ON asdf.tBestellung_kBestellung = [login to view URL] WHERE asdf.tArtikel_kArtikel = [login to view URL] AND [login to view URL] > @InventurDatum and [login to view URL] < @InventurDatum2 ) as Verkauf, CAST((select A.fLagerbestand-coalesce(sum([login to view URL]),0 ) FROM [eazybusiness].[dbo].[tArtikelHistory] AS D WHERE A.kArtikel=[login to view URL] and [login to view URL] != 1AND [login to view URL] > @InventurDatum) AS int) as 'Anfang', CAST((select A.fLagerbestand-coalesce(sum([login to view URL]),0 ) FROM [eazybusiness].[dbo].[tArtikelHistory] AS D WHERE A.kArtikel=[login to view URL] and [login to view URL] != 1AND [login to view URL] > @InventurDatum2) AS int) as 'Ende' FROM [eazybusiness].[dbo].[tlagerbestand] AS A LEFT JOIN tArtikelBeschreibung cd ON [login to view URL] = [login to view URL] LEFT JOIN [eazybusiness].[dbo].[tArtikel] AS B ON [login to view URL] = [login to view URL] WHERE [login to view URL] != 1 AND [login to view URL] = 1 and [login to view URL] = 1 order by [login to view URL] asc ####### What we need is kind of loop within this query through each day between @ InventurDatum and @ InventurDatum2 which returns the amount for each day in a single row with the day as the rows headline.
Prosjekt-ID: 16507041

Om prosjektet

13 forslag
Eksternt prosjekt
Aktiv 6 år siden

Ønsker du å tjene penger?

Fordeler med budgivning på Freelancer

Angi budsjettet og tidsrammen
Få betalt for arbeidet ditt
Skisser forslaget ditt
Det er gratis å registrere seg og by på jobber
Tildelt til:
Brukeravatar
Hi. I'm professional software developer with more than 15 years of experience. I'm able to improve the query.
€40 EUR om 1 dag
5,0 (3 omtaler)
3,4
3,4
13 frilansere byr i gjennomsnitt €24 EUR for denne jobben
Brukeravatar
Hi I am a database expert with 15 years experience in handling MS SQL databases. I have worked as DBA for large ERP databases and use to write and do performance tuning for SQL queries, procedures and triggers. We might not need a loop, rather this could be possible by doing a group by on the dGebucht column, but I can confirm after taking a closer look. I can work on this either by getting a table scripts and some sample data, or by connecting to your server on team viewer. Look forward to hear from you. Thanks Roni
€25 EUR om 1 dag
5,0 (77 omtaler)
6,4
6,4
Brukeravatar
Hi, would you mind send me a .bak witha subset of the data, I know how to do CURSORs loops in SQL Server with FETCH operations, don't know if that would be the best ways to achieve results here, but I have to see a subset of data, to see what would be the best recommendation Thanks, Felice
€30 EUR om 1 dag
5,0 (11 omtaler)
6,2
6,2
Brukeravatar
its pleasure to work the optimizations part and automation parts , if you would like to believe I could give you the best , please let me know . waiting for response
€24 EUR om 0 dag
4,9 (21 omtaler)
4,5
4,5
Brukeravatar
Hi, I am having expert level experience in SQL Server last 7 years. I would like to work in this project. I will provide you quality output withing a time frame we define. Please let us know your convenient time to discuss further. Kind Regards, Mayuri Patel.
€39 EUR om 10 dager
5,0 (4 omtaler)
4,1
4,1
Brukeravatar
Hi I'm ready for this project. I'm expert in MS SQL. Please give me an opportunity. I will do it perfectly.
€15 EUR om 1 dag
5,0 (8 omtaler)
3,1
3,1
Brukeravatar
Hi, I'm expert in software building domain, having good exposure to backend & frontend programming. I feel I can complete your job. Please consider my profile. Thanks Regards, Gagan
€23 EUR om 1 dag
0,0 (0 omtaler)
0,0
0,0
Brukeravatar
A proposal has not yet been provided
€12 EUR om 2 dager
0,0 (0 omtaler)
0,0
0,0
Brukeravatar
A proposal has not yet been provided
€24 EUR om 3 dager
0,0 (0 omtaler)
0,0
0,0
Brukeravatar
Hello dear Hiring manager I have read your job post & being an expert Web developer, I offer myself for the job. I am having extensive knowledge and 5+ years of experience in PHP & WordPress website development using the best practice & standard plugins, and expert in MySQL, HTML, CSS and JavaScript. My Experience Include - HTML5, CSS3, Angulor js , Node js, Mongo DB, CI Ionic , mobile jquery Custom Responsive Design W3C validation PHP Laravell WOrdpress Theme/Template integration and customization Site Optimization PSD to HTML conversion Configuration and Installation of plugins/widgets/Custom features Creation of clean, logical, well-documented and re-usable code SEO friendly Design and Coding Thanks and Regards,
€23 EUR om 1 dag
0,0 (0 omtaler)
0,0
0,0

Om klienten

GERMANYs flagg
Ettlingen, Germany
5,0
6
Betalingsmetode bekreftet
Medlem siden jan. 5, 2018

Klientbekreftelse

Takk! Vi har sendt deg en lenke for at du skal kunne kreve din gratis kreditt.
Noe gikk galt. Vær så snill, prøv på nytt.
Registrerte brukere Publiserte jobber
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Forhåndsvisning innlasting
Tillatelse gitt for geolokalisering.
Påloggingsøkten din er utløpt og du har blitt logget ut. Logg på igjen.