Data composition schema condition

Common questions about 1C:Query language, Query builder tool and Data composition schema

#1
People who like this:0Yes/0No
Interested
Rating: 32
Joined: Oct 27, 2011
Company: Abaco Soluciones S.A.

I could make two different queries fro the report:
include condition to virtual table

Code
SEL ECT
   ContabilidadTurnovers.ValorTurnover,
   ContabilidadTurnovers.CantidadTurnover,
   ContabilidadTurnovers.Empresa,
   ContabilidadTurnovers.ExtDimension1
FR OM
   AccountingRegister.Contabilidad.Turnovers(, , , Account = &SlaesAccount, , Empresa = &Empresa, , ) 
   AS ContabilidadTurnovers


or just use a filter in data composition schema for filtering Empresa.

The first option should work faster, but it have a problem if the Empresa parameter is not defined - the query ended with an error. The second one is more versatile and give us more options. Are there any optimizations which make use of second method as effective as the first one. And how is recommendable?

 
#2
People who like this:0Yes/0No
Timofey Bugaevsky
Guest

Joined:
Company:

Virtual table parameters will work faster. To optimize your report you should set it when work with large amount of data. If the data is not that large you can use more versalite mechanisms to provide more flexibility.

 
Subscribe
Users browsing this topic (guests: 1, registered: 0, hidden: 0)
Be the first to know tips & tricks on business application development!

A confirmation e-mail has been sent to the e-mail address you provided .

Click the link in the e-mail to confirm and activate the subscription.