Mombu the Programming Forum sponsored links

Go Back   Mombu the Programming Forum > Programming > Programming languages > exporting
User Name
Password
REGISTER NOW! Mark Forums Read

sponsored links


Reply
 
1 22nd October 19:36
apoc
External User
 
Posts: 1
Default exporting



Hi everyone...

can somebody please help me...
i have a queue that i want to export to a .csv file.
can somebody please just give me a idea of how the code should look
like?

thanx in advance
  Reply With Quote


  sponsored links


2 22nd October 19:40
mpollux_ork
External User
 
Posts: 1
Default exporting



Apoc ha escrito:


Hi.

First, you have to declare your file in Global Embeds like this:

!Declares Output CSV File
ArchSal File, Driver('Basic','/ALWAYSQUOTE=off'), Name('Eventos.csv'),
PRE(SAL), Create
Registro Record
Evento String(4)
Sku String(9)
DesEvento String(32)
Start String(10)
Stop String(10)
PriceEvt Decimal(15,2)
Promo_Code String(1)
DesSku String(30)
PriceMst Decimal(15,2)
End
End

And then, you add the procedure, either in a button or as a routine.
My queue is ListaResultados. The prefix is QRE


!Generates output file
Create(ArchSal)
Open(ArchSal)
Loop Regs# = 1 to Records(ListaResultados)
Get(ListaResultados,Regs#)
SAL:Evento=QRE:Evento
SAL:Sku=QRE:Sku
SALesEvento=QREesEvento
SAL:Start=Format(QRE:Start,@D17)
SAL:Stop=Format(QRE:Stop,@D17)
SAL:PriceEvt=QRE:PriceEvt
SAL:Promo_Code=QRE:Promo_Code
SALesSku=QREesSku
SAL:PriceMst=QRE:PriceMSt
Add(ArchSal)
End
Close(ArchSal)

I hope this will help.
  Reply With Quote
3 24th February 08:23
mpollux_ork
External User
 
Posts: 1
Default exporting


Apoc ha escrito:


Hi.

First, you have to declare your file in Global Embeds like this:

!Declares Output CSV File
ArchSal File, Driver('Basic','/ALWAYSQUOTE=off'), Name('Eventos.csv'),
PRE(SAL), Create
Registro Record
Evento String(4)
Sku String(9)
DesEvento String(32)
Start String(10)
Stop String(10)
PriceEvt Decimal(15,2)
Promo_Code String(1)
DesSku String(30)
PriceMst Decimal(15,2)
End
End

And then, you add the procedure, either in a button or as a routine.
My queue is ListaResultados. The prefix is QRE


!Generates output file
Create(ArchSal)
Open(ArchSal)
Loop Regs# = 1 to Records(ListaResultados)
Get(ListaResultados,Regs#)
SAL:Evento=QRE:Evento
SAL:Sku=QRE:Sku
SALesEvento=QREesEvento
SAL:Start=Format(QRE:Start,@D17)
SAL:Stop=Format(QRE:Stop,@D17)
SAL:PriceEvt=QRE:PriceEvt
SAL:Promo_Code=QRE:Promo_Code
SALesSku=QREesSku
SAL:PriceMst=QRE:PriceMSt
Add(ArchSal)
End
Close(ArchSal)

I hope this will help.
  Reply With Quote


  sponsored links


Reply


Thread Tools
Display Modes




Copyright © 2006 SmartyDevil.com - Dies Mies Jeschet Boenedoesef Douvema Enitemaus -
666