Wednesday, March 21, 2012
Future of Report builder
I am looking into letting users build their own reports. So far, it
looks good for most scenarios. However, some of the 'reports' I'd
like users to create are forms for our quotes, orders and invoices.
I can create these kinds of reports in VS 2005, but I can't in report
builder because of its lack of the List control. I use the list
control to display fields from the Document header data source, which
will only ever have one item in the list such as sold to information,
the document number, etc.
Will report builder gain the ability to use the List control so that i
can place item details arbitrary on the form? I'd like to see this
feature added, as it would allow my users to create any kind of
reports / forms they need so long as I provide them an appropriate
model.
For now, are there any workarounds?
Thanks
AndyBasically RB is for top management, who can create report on their own, for
forms you can try using "Infopath" for forms creation. Since it is a very
very earlier version, we expect MS will improve on it.
Amarnath
"Andy" wrote:
> Hi,
> I am looking into letting users build their own reports. So far, it
> looks good for most scenarios. However, some of the 'reports' I'd
> like users to create are forms for our quotes, orders and invoices.
> I can create these kinds of reports in VS 2005, but I can't in report
> builder because of its lack of the List control. I use the list
> control to display fields from the Document header data source, which
> will only ever have one item in the list such as sold to information,
> the document number, etc.
> Will report builder gain the ability to use the List control so that i
> can place item details arbitrary on the form? I'd like to see this
> feature added, as it would allow my users to create any kind of
> reports / forms they need so long as I provide them an appropriate
> model.
> For now, are there any workarounds?
> Thanks
> Andy
>
Monday, March 19, 2012
Functions?
WIthin SQL Server 2005, there are functions. This feature is new to me and I haven't found anyone that has written their own fucntions? I'm wondering if functions are written the same as stored procedures, and can a function be called from a stored procedure or even from within a query.
Yes SQL functions are pretty much like your VB or any other functions. They take one/more parameters return one value. You could also return a table from a function. You can call the function from a Query or even inside a stored procedure. You can read up Books On Line for more info. There are some built in functions too.|||
Functions are not new to SQL Server 2005, they were introduced in SQL Server 2000. Try the link below for answers about most known UDF. The site is run by a UDF expert. Hope this helps.
http://www.novicksoftware.com/UDFofWeek/UDF_FAQ.htm
Friday, March 9, 2012
function on linked server
select * from index_gold_iif('20040121')
When I try do it from linked serwer:
select * from
lewiatan.e_.dbo.index_gold_iif('20040121')
I have massage:
Server: Msg 170, Level 15, State 31, Line 2
Line 4: Incorrect syntax near '('.
As I understand server can't see function from linked server. Is it true or
I have done some error (what)?
Marek
PS. all done on "sa" userMarek
No, server can see functions
select * from openquery
(servername,'select * from
dbo.fn_dates(''20040101'',''20040110'')') --this function returns range
of date between given dates
"Marek Wierzbicki" <marek.wierzbicki.___@.azymut.pl> wrote in message
news:bv35q6$cuh$1@.news2.ipartners.pl...
> I have my own function, which I can use:
> select * from index_gold_iif('20040121')
> When I try do it from linked serwer:
> select * from
> lewiatan.e_.dbo.index_gold_iif('20040121')
> I have massage:
> Server: Msg 170, Level 15, State 31, Line 2
> Line 4: Incorrect syntax near '('.
> As I understand server can't see function from linked server. Is it true
or
> I have done some error (what)?
> Marek
> PS. all done on "sa" user
>
>|||> No, server can see functions
> select * from openquery
> (servername,'select * from
> dbo.fn_dates(''20040101'',''20040110'')') --this function returns
range
> of date between given dates
OPENQUERY - I don't know this function up today. What about optimalization
with this function - isn't it so slow as exec('query string")?
Can I use this function to make query like:
select * from va_name_table
for example:
select * from openquery(localhost, 'select * from '+@.table_name)?
Marek|||> No, server can see functions
> select * from openquery
> (servername,'select * from
> dbo.fn_dates(''20040101'',''20040110'')') --this function returns
range
> of date between given dates
there something wrongs with openquery - it didn't recognize query string
bild on the fly. So what for call openquery with string to connect to
function, which I need to write parametr of this funcion once forewer?
Marek
PS. example with error:
declare @.dt as datetime
declare @.s as varchar(520)
select @.dt='20040121 12:22:33'
select @.s='select * from e_.dbo.index_gold_iif('+convert(varchar(22), @.dt,
112)+' '+convert(varchar(22), @.dt, 108)+')'
print @.s -- up to this place workong OK
select * from OPENQUERY(lewiatan , @.s) -- this is not working
Server: Msg 170, Level 15, State 1, Line 8
Line 8: Incorrect syntax near '@.s'.|||> No, server can see functions
> select * from openquery
> (servername,'select * from
> dbo.fn_dates(''20040101'',''20040110'')') --this function returns
range
> of date between given dates
I think its wrong answer beacouse openquery is run (as I read) on linked
server, not local
Marek
function on linked server
select * from index_gold_iif('20040121')
When I try do it from linked serwer:
select * from
lewiatan.e_.dbo.index_gold_iif('20040121')
I have massage:
Server: Msg 170, Level 15, State 31, Line 2
Line 4: Incorrect syntax near '('.
As I understand server can't see function from linked server. Is it true or
I have done some error (what)?
Marek
PS. all done on "sa" userMarek
No, server can see functions
select * from openquery
(servername,'select * from
dbo.fn_dates(''20040101'',''20040110'')') --this function returns range
of date between given dates
"Marek Wierzbicki" <marek.wierzbicki.___@.azymut.pl> wrote in message
news:bv35q6$cuh$1@.news2.ipartners.pl...
quote:
> I have my own function, which I can use:
> select * from index_gold_iif('20040121')
> When I try do it from linked serwer:
> select * from
> lewiatan.e_.dbo.index_gold_iif('20040121')
> I have massage:
> Server: Msg 170, Level 15, State 31, Line 2
> Line 4: Incorrect syntax near '('.
> As I understand server can't see function from linked server. Is it true
or
quote:|||> No, server can see functions
> I have done some error (what)?
> Marek
> PS. all done on "sa" user
>
>
quote:
> select * from openquery
> (servername,'select * from
> dbo.fn_dates(''20040101'',''20040110'')') --this function returns
range
quote:
> of date between given dates
OPENQUERY - I don't know this function up today. What about optimalization
with this function - isn't it so slow as exec('query string")?
Can I use this function to make query like:
select * from va_name_table
for example:
select * from openquery(localhost, 'select * from '+@.table_name)?
Marek|||> No, server can see functions
quote:
> select * from openquery
> (servername,'select * from
> dbo.fn_dates(''20040101'',''20040110'')') --this function returns
range
quote:
> of date between given dates
there something wrongs with openquery - it didn't recognize query string
bild on the fly. So what for call openquery with string to connect to
function, which I need to write parametr of this funcion once forewer?
Marek
PS. example with error:
declare @.dt as datetime
declare @.s as varchar(520)
select @.dt='20040121 12:22:33'
select @.s='select * from e_.dbo.index_gold_iif('+convert(varchar(22), @.dt,
112)+' '+convert(varchar(22), @.dt, 108)+')'
print @.s -- up to this place workong OK
select * from OPENQUERY(lewiatan , @.s) -- this is not working
Server: Msg 170, Level 15, State 1, Line 8
Line 8: Incorrect syntax near '@.s'.|||> No, server can see functions
quote:
> select * from openquery
> (servername,'select * from
> dbo.fn_dates(''20040101'',''20040110'')') --this function returns
range
quote:
> of date between given dates
I think its wrong answer beacouse openquery is run (as I read) on linked
server, not local
Marek
Wednesday, March 7, 2012
function and linked server
declare @.dt as datetime
select @.dt='20040121 12:22:33'
select * from index_gold_iif(@.dt)
When I try do it from linked serwer:
declare @.dt as datetime
select @.dt='20040121 12:22:33'select * from
lewiatan.e_.dbo.index_gold_iif(@.dt)
I have massage:
Server: Msg 170, Level 15, State 31, Line 2
Line 4: Incorrect syntax near '('.
Did server can't see function from linked server? Is it true or I have done
some error (what)?
Marek
PS. all done as "sa" user, linked server linked with sa account"Marek Wierzbicki" <marek.wierzbicki.___@.azymut.pl> wrote in message
news:bv39u8$g4g$1@.news2.ipartners.pl...
> I have my own function, which I can use:
> declare @.dt as datetime
> select @.dt='20040121 12:22:33'
> select * from index_gold_iif(@.dt)
> When I try do it from linked serwer:
> declare @.dt as datetime
> select @.dt='20040121 12:22:33'select * from
> lewiatan.e_.dbo.index_gold_iif(@.dt)
> I have massage:
> Server: Msg 170, Level 15, State 31, Line 2
> Line 4: Incorrect syntax near '('.
> Did server can't see function from linked server? Is it true or I have
done
> some error (what)?
> Marek
> PS. all done as "sa" user, linked server linked with sa account
UDFs aren't supported directly on linked servers, but you can use
OPENQUERY() as a workaround:
http://support.microsoft.com/defaul...b;en-us;Q319138
Simon|||> > declare @.dt as datetime
> > select @.dt='20040121 12:22:33'
> > select * from index_gold_iif(@.dt)
> UDFs aren't supported directly on linked servers, but you can use
> OPENQUERY() as a workaround:
> http://support.microsoft.com/defaul...b;en-us;Q319138
both of them isn't good, beacouse my function return table (there is "view
with parametr")
Marek|||> > UDFs aren't supported directly on linked servers, but you can use
> > OPENQUERY() as a workaround:
> > http://support.microsoft.com/defaul...b;en-us;Q319138
OK works for function returned table
Marek