Quantcast
Channel: SQL Server Reporting Services, Power View forum
Viewing all articles
Browse latest Browse all 10045

SSRS and Stored Procedure Processing

$
0
0

I have a SSRS report that I want to bring in the start & end date. No problem there. But I want to change the dates to the format of the field I am selecting by. 

The field is called importid and starts with 98 then date CCYYMMDD and then 3. I figured I could create some variables and format the selection fields. But I keep getting errors that varchar data cannot be converted. 

Here is is my code for converting the variables to the format.

DECLARE    @StartImport bigint,

           @EndImport bigint,

           @Number varchar(11)

Set @Number = '98' + LEFT(@StartDate,8) + '3'

Set @StartImport = convert(bigint, @Number)

Set  @Number = '98' + LEFT(@StartDate,8) + '3'

Set @EndImport = convert(bigint, @Number)


Viewing all articles
Browse latest Browse all 10045

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>