+ Start a Discussion
sathisathi 

pls give me solution



share price value is changing every one hour in share market......im updating that value in my account stock history object......

for example ibm company has 130(morning 9am)

                                                         120(morning 10am)

                                                         125(morning 11 am).......like that

  i need  first price(open price) in my visual force page how i can get it?

Best Answer chosen by Admin (Salesforce Developers) 
JBabuJBabu

Hi,

 

 

I am building query based upon your details. You need to change the fields.

 

select Id, time__c from act_stk_hist__c where createddate = today order by time__c asc limit 1

All Answers

JBabuJBabu

Hi,

 

 

I am building query based upon your details. You need to change the fields.

 

select Id, time__c from act_stk_hist__c where createddate = today order by time__c asc limit 1

This was selected as the best answer
sathisathi

thank you ..... im getting with this but a small problem..........how we can get time in time__C field  of account_stock_history object from account object.?

JBabuJBabu

Hi,

 

I think  "account_stock_history__c" has account as look up.

Lets assume "time" is field of account object and "time__c" field of "account_stock_history__c" object.

 

time__c - needs to be formula field (formula)

time__c = account.time

 

Thanks,

Babu.

sathisathi
i ggot the answer by using time__c=datetime.now() thank you so much.
sathisathi

one more doubt  ...im maintaing today stock history in account_stock_history object....and i have to maintain yesterday stock history also in account_stock_history_object how can i?

JBabuJBabu

the query which u r using u can included the condition

 

 

createddate >= yesterday

sathisathi
is yesterday standard field?
sathisathi
it is useful to me .........thank you