sql - Error while converting from getdate() function -


on command line

convert(varchar,getdate(),120)  

gives below error:

unknown argument '04:59:42.xml'

i saving data xml file. when use below command,proc works perfectly.

convert(varchar,getdate(),112) 

i need file save time.

you trying create file colon in name, not allowed. no way around restriction. however, can replace colons other characters when naming file, e.g.

replace(convert(varchar,getdate(),120),':','') 

Comments

Popular posts from this blog

ubuntu - PHP script to find files of certain extensions in a directory, returns populated array when run in browser, but empty array when run from terminal -

php - How can i create a user dashboard -

javascript - How to detect toggling of the fullscreen-toolbar in jQuery Mobile? -